package com.service.FxyService;

import com.bean.Fxy.Fangwutianja;
import com.dao.Fxy.FangwData;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.sql.SQLException;

@Service
public class FwService {
        @Autowired
        private FangwData dh;

        /**
         * 显示页面
         */
        public Object xianshiserver(){
            return dh.housesDao();
        }

        /**
         * 删除
         * @param hid
         * @return
         */
        public Object servershanchu(int hid)  {
            return  dh.shanchuDao(hid);
        }
        /**
         * 楼宇下拉框获取值
         */
        public Object serverlouyuxl(){
            return  dh.louyuxialaDao();
        }

        /**
         * 楼宇下拉框获取值
         */
        public Object serverdanyuanxl(Integer lyxl){

            return  dh.danyuanxialaDao(lyxl);
        }

        /**
         * 住户下拉框获取值
         */
        public Object serverzhuhuxl(){

            return  dh.zhuhiuxialaDao();
        }

        /**
         * 添加
         * @param houses
         * @return
         */

        public Object servertj(Fangwutianja houses){

            return  dh.tjDao(houses);
        }


        /**
         * 确认修改
         * @param houses
         * @return
         */

        public Object serverxiugia(Fangwutianja houses){

            return  dh.qrtxgDao(houses);
        }

        /**
         * 修改页面赋值
         * @param td2
         * @return
         */
        public Object serverxg(int td2){


            return dh.xgDao(td2);
        }

        /**
         * 综合查询
         * @param lycx
         * @param ducx
         * @return
         */

        public Object serverxg(int lycx,int ducx){


            return dh.selectHorese(lycx,ducx);
        }

    }


